<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ include file="/WEB-INF/view/inc.jsp" %>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
</head>
<body>

<div class="dialog_form">
    <form id="fm" method="post" action="<%=contextPath%>/sys/resource/saveAndUpdate" novalidate>
        <input type="hidden" name="id" value="${resource.id}"/>

        <div class="dialog_item">
            <label>资源名称:</label>
            <input id="resourceName" name="resourceName" class="no-space easyui-textbox " required="true"
                   validType="length[0,20]" value="${resource.resourceName}"> 
        </div>
        <div class="dialog_item">
            <label>资源类型:</label>
            <input name="resourceType" editable="false" value="${resource.resourceType}" required="true"
                   class="easyui-combobox " data-options="valueField : 'code',
	    						textField : 'name', url:'<%=contextPath%>/sys/codeItems/byCategoryCode?categoryCode=resourceType',
								panelHeight:'auto'
							">
        </div>
        <div class="dialog_item">
            <label>资源路径:</label>
            <input id="resourceUrl" name="resourceUrl" class="no-space easyui-textbox " required="true"
                   validType="length[0,100]" value="${resource.resourceUrl}"> 
        </div>

        <div class="dialog_item">
            <label>上级资源:</label>
            <input name="parentId" class="easyui-combotree "
                   value="${resource.parentId}"
                   data-options=" editable:false,parentField:'parentId',url:'<%=contextPath%>/sys/resource/commonTree',method:'get' "/>
        </div>

        <div class="dialog_item">
            <label>排序:</label>
            <input name="sortIndex" class="easyui-numberbox " validType="length[0,10]" value="${resource.sortIndex}">
        </div>


        <div class="dialog_item">
            <label>状态:</label>
            <input name="status" editable="false" value="${resource.status}" required="true"
                   class="easyui-combobox " data-options="valueField : 'code',textField : 'name', url:'<%=contextPath%>/sys/codeItems/byCategoryCode?categoryCode=status',
								panelHeight:'auto'
							">
        </div>
        <div class="dialog_item">
            <label>图标:</label>
            <input name="iconCls" class="easyui-textbox " validType="length[0,100]" value="${resource.iconCls}">
        </div>
        <div class="dialog_item">
            <label>事件函数:</label>
            <input name="clickFun" class="easyui-textbox " validType="length[0,300]" value="${resource.clickFun}">
        </div>
        <div class="dialog_item">
            <label>资源描述:</label>
            <input name="resourceDesc" class=" easyui-textbox " data-options="multiline:true" validType="length[0,200]"
                   value="${resource.resourceDesc}"
                   style="height:80px">
        </div>
    </form>
</div>
</body>
</html>
